package com.jg.service.impl;

import com.jg.entity.Dormitory;
import com.jg.mapper.DormitoryMapper;
import com.jg.service.DormitoryService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

/**
 * @author 86130
 * @version 1.0
 * @description: TODO
 * @date 2025/6/6 上午11:53
 */
@Service
public class DormitoryServiceImpl implements DormitoryService {
    @Autowired
    private DormitoryMapper dormitoryMapper;
    @Override
    public List<Dormitory> findAllDormitory() {
        return dormitoryMapper.findAllDormitory();
    }

    @Override
    public void findDormitoryById(Integer id) {
        dormitoryMapper.findDormitoryById(id);
    }

    @Override
    public int addDormitory() {
        return dormitoryMapper.addDormitory();
    }

    @Override
    public int updateDormitory(Integer id) {
        return dormitoryMapper.updateDormitory(id);
    }

    @Override
    public int deleteDormitory(Integer id) {
        return dormitoryMapper.deleteDormitory(id);
    }
}
